<?php /* Smarty version 2.6.20, created on 2016-04-11 19:43:58
         compiled from shop_bonus_list.htm */ ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>微店红包列表</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link href="admin.css" rel="stylesheet" type="text/css" />
<link href="cxcalendar.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="../script/jquery-1.4.4.min.js"></script>
<script language="javascript" src="../script/Calendar-new.js"></script>
<script type="text/javascript">
$(function(){
	//时间搜索
	$('.input_cxcalendar').each(function(){
	    var a = new Calendar({
	        targetCls: $(this),
	        type: 'yyyy-mm-dd HH:MM:SS',
	        wday:2
	    },function(val){
	        console.log(val);
	    });
	});
});
</script>
</head>
<body>
<div class="container">
    <div class="flow">
        <div class="itemtitle">
            <h3>红包列表</h3>
        </div>
    </div>
    <div class="h35"></div>
    
    <form action="" method="get">
	    <input type="hidden" name="m" value="<?php echo $_GET['m']; ?>
">
	    <input type="hidden" name="s" value="<?php echo $_GET['s']; ?>
">
	    <table>
	        <tr>
	        	<td>会员：</td>
                <td>
                	<textarea name="member_id" placeholder="会员ID，支持逗号分隔的多个"><?php echo $_GET['member_id']; ?>
</textarea>
               	</td>
	        	<td>红包类型：</td>
                <td>
                	<select name="type">
                		<option value="">全部</option>
						<?php $_from = $this->_tpl_vars['bonus_type']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
    foreach ($_from as $this->_tpl_vars['key'] => $this->_tpl_vars['type']):
?>
						<option value="<?php echo $this->_tpl_vars['key']; ?>
" <?php if ($_GET['type'] == $this->_tpl_vars['key']): ?>selected<?php endif; ?>><?php echo $this->_tpl_vars['type']; ?>
</option>
						<?php endforeach; endif; unset($_from); ?>
                	</select>
                </td>
	        	<td>状态：</td>
                <td>
                	<select name="status">
                		<option value="">全部</option>
						<option value="0" <?php if ($_GET['status'] == '0'): ?>selected<?php endif; ?>>未领取</option>
                		<option value="1" <?php if ($_GET['status'] == 1): ?>selected<?php endif; ?>>已领取</option>
                		<option value="-1" <?php if ($_GET['status'] == -1): ?>selected<?php endif; ?>>无效</option>
                	</select>
                </td>
                <td>发放时间：</td>
                <td>
                    <input class="w120 input_cxcalendar" type="text" name="stime" id="stime" value="<?php echo $_GET['stime']; ?>
"">
                    -
                    <input class="w120 input_cxcalendar" type="text" name="etime" id="etime" value="<?php echo $_GET['etime']; ?>
"">
	            </td>
	            <td>领取记录ID：</td>
                <td>
                	<input type="text" name="record_id" value="<?php echo $_GET['record_id']; ?>
" />
               	</td>
               	<td>关联ID：</td>
                <td>
                	<input type="text" name="relation_id" value="<?php echo $_GET['relation_id']; ?>
" placeholder="订单ID/推荐店铺ID" />
               	</td>
	            <td>
                	<input type="submit" value="搜索" />
            	</td>
	        </tr>
	    </table>
    </form>
    
    <table class="table product">
       <tbody>
       <tr class="header">
            <th width="100">红包ID</th>
            <th width="100">店铺</th>
            <th width="100">红包类型</th>
            <th width="100">红包金额</th>
            <th width="100">订单ID/推荐店铺ID</th>
            <th width="100">可结算时间</th>
            <th width="100">红包状态</th>
            <th width="100">领取时间</th>
            <th width="100">创建时间</th>
        </tr>
        <?php $_from = $this->_tpl_vars['de']['list']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
    foreach ($_from as $this->_tpl_vars['key'] => $this->_tpl_vars['list']):
?>
        <tr>
            <td><?php echo $this->_tpl_vars['list']['id']; ?>
</td>
            <td>店铺ID:<?php echo $this->_tpl_vars['list']['member_id']; ?>
<br />店铺名称:<?php echo $this->_tpl_vars['list']['shop_name']; ?>
</td>
            <td><?php echo $this->_tpl_vars['list']['type']; ?>
</td>
            <td><?php echo $this->_tpl_vars['config']['money']; ?>
<?php echo $this->_tpl_vars['list']['price']; ?>
</td>
            <td><?php echo $this->_tpl_vars['list']['relation_id']; ?>
</td>
            <td><?php echo $this->_tpl_vars['list']['p_settle_time']; ?>
</td>
            <td>
            <?php if ($this->_tpl_vars['list']['status'] == 0): ?>未领取<?php endif; ?>
            <?php if ($this->_tpl_vars['list']['status'] == 1): ?>已领取<?php endif; ?>
            <?php if ($this->_tpl_vars['list']['status'] == -1): ?>无效<?php endif; ?>
            </td>
            <td><?php echo $this->_tpl_vars['list']['get_time']; ?>
</td>
            <td><?php echo $this->_tpl_vars['list']['create_time']; ?>
</td>
        </tr>
        <?php endforeach; else: ?>
        <tr>
            <td class="norecord" colspan="99"><i></i><span>暂无符合条件的数据记录</span></td>
        </tr>
        <?php endif; unset($_from); ?>
		</tbody>
        <tfoot>
            <tr>
                <td colspan="99">
                	<div class="fl">每页最多显示： <?php echo $this->_tpl_vars['de']['perPageRows']; ?>
条</div>
                    <div class="page"><?php echo $this->_tpl_vars['de']['page']; ?>
</div>
                    <div class="fr">共有<?php echo $this->_tpl_vars['de']['count']; ?>
条记录</div>
                    <br /><div class="fr">共计：<?php echo $this->_tpl_vars['de']['total_price']; ?>
元</div>
                </td>
            </tr>
        </tfoot>
    </table>
</div>
</body>
</html>